﻿/*
*设置只读
*/
function SetReadOnly()
{
    //textbox and button
    jQuery("input").each(function(){
        if(this.id.indexOf('btnBack') == -1 && this.type != 'hidden')
        {
            this.disabled = true;
            //隐藏其他ImageButton
            if(this.type == 'image')
                this.style.display = 'none';
        }
    });
    
    //文本框    
    jQuery("TEXTAREA").each(function () {
        this.disabled = true;
    });
    
    //下拉框
    jQuery("select").each(function () {
        this.disabled = true;
    });
    
    //链接
    jQuery("a").each(function() {
        if(this.id.indexOf('btnPreview') == -1)
        {
            this.disabled = true;
            this.href = '#';
        }
    });    

}